import TDbStorage from './TDbStorage';

class Token {
  tdToken: any;
  constructor(name: string) {
    this.tdToken = new TDbStorage(name);
  }
  set(value: USER.loginResult) {
    return this.tdToken.set({
      name: 'tt',
      path: '',
      value: value,
    });
  }
  get() {
    return this.tdToken.get({
      name: 'tt',
    });
  }
}

export default new Token('xjctoken');
